﻿using blackhouse.BlackApart.Business.Apartments;
using blackhouse.BlackApart.Web;
using blackhouse.WebNemo.Business.Groups;
using blackhouse.WebNemo.Web;
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Web;

namespace blackhouse.StareKino.Web {
    public class StareKinoHelper {

        public static string GetApartmentPhotoUrl(IApartmentPhoto photo, Size photoSize) {
            GroupRecord photoRecord = photo as GroupRecord;
            if (photoRecord != null)
                return WebNemoUtils.GetImageUrl(photoRecord, "zdjecie", photoSize);
            else
                return UrlUtils.GetDbImageUrl("Apartment-photo", photo.PhotoName, photoSize);
        }
    }
}